package com.yoake.campus.domain.vo;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import com.yoake.campus.domain.CampusContent;
import com.yoake.common.config.deserializer.StringToListDeserializer;
import lombok.Data;

import java.util.Date;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

@Data
public class CampusContentVo extends CampusContent {
    /**
     * 文件列表
     */
    @JsonDeserialize(using = StringToListDeserializer.class)
    private List<String> fileList;


    /**
     * 备注
     */
    private String remark;


    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date createTime;

    private Map<String, Object> params;

    public Map<String, Object> getParams() {
        if (params == null) {
            params = new HashMap<>();
        }
        return params;
    }
}


